<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>line</title>
</head>
<body>
    <svg width="200px" height="200px" viewBox="0 0 200 200" xmlns="http://www.w3c.org/2000/svg">
        <!-- 水平线段 -->
        <line x1="40" y1="20" x2="80" y2="20" style="stroke: black;" />
        
        <!--垂直线段-->
        <line x1="0.7cm" y1="1cm" x2="0.7cm" y2="2.0cm" style="stroke: black;" />
        
        <!--对角线段-->
        <line x1="30" y1="30" x2="85" y2="85" style="stroke: black;" />
    </svg>
</body>
</html>